package com.ztorn.fiscale.mapper;

import java.util.List;
import com.ztorn.fiscale.domain.FiscaleTaxDeclarationRelation;

/**
 * 报关单发票关联Mapper接口
 *
 * @author ztorn
 * @date 2025-01-19
 */
public interface FiscaleTaxDeclarationRelationMapper
{
    /**
     * 查询报关单发票关联
     *
     * @param relationId 报关单发票关联主键
     * @return 报关单发票关联
     */
    public FiscaleTaxDeclarationRelation selectFiscaleTaxDeclarationRelationById(Long relationId);

    /**
     * 查询报关单发票关联列表
     *
     * @param fiscaleTaxDeclarationRelation 报关单发票关联
     * @return 报关单发票关联集合
     */
    public List<FiscaleTaxDeclarationRelation> selectFiscaleTaxDeclarationRelationList(FiscaleTaxDeclarationRelation fiscaleTaxDeclarationRelation);

    /**
     * 新增报关单发票关联
     *
     * @param fiscaleTaxDeclarationRelation 报关单发票关联
     * @return 结果
     */
    public int insertFiscaleTaxDeclarationRelation(FiscaleTaxDeclarationRelation fiscaleTaxDeclarationRelation);

    /**
     * 修改报关单发票关联
     *
     * @param fiscaleTaxDeclarationRelation 报关单发票关联
     * @return 结果
     */
    public int updateFiscaleTaxDeclarationRelation(FiscaleTaxDeclarationRelation fiscaleTaxDeclarationRelation);

    /**
     * 删除报关单发票关联
     *
     * @param relationId 报关单发票关联主键
     * @return 结果
     */
    public int deleteFiscaleTaxDeclarationRelationById(Long relationId);

    /**
     * 批量删除报关单发票关联
     *
     * @param relationIds 需要删除的数据主键集合
     * @return 结果
     */
    public int deleteFiscaleTaxDeclarationRelationByIds(Long[] relationIds);

    /**
     * 通过发票ID删除报关单发票关联信息
     *
     * @param invoiceId 发票ID
     * @return 结果
     */
    public int deleteFiscaleTaxDeclarationRelationByInvoiceId(Long invoiceId);

    /**
     * 通过报关单ID查询关联信息
     *
     * @param declarationId 报关单ID
     * @return 报关单发票关联
     */
    public FiscaleTaxDeclarationRelation selectFiscaleTaxDeclarationRelationByDeclarationId(Long declarationId);

    /**
     * 通过发票ID查询关联信息
     *
     * @param invoiceId 发票ID
     * @return 报关单发票关联
     */
    public List<FiscaleTaxDeclarationRelation> selectFiscaleTaxDeclarationRelationByInvoiceId(Long invoiceId);

    /**
     * 批量新增报关单发票关联
     *
     * @param relations 报关单发票关联列表
     * @return 结果
     */
    public int insertFiscaleTaxDeclarationRelations(List<FiscaleTaxDeclarationRelation> relations);

    /**
     * 通过报关单ID删除报关单发票关联信息
     *
     * @param declarationId 报关单ID
     * @return 结果
     */
    public int deleteFiscaleTaxDeclarationRelationByDeclarationId(Long declarationId);
}
